Note. Boxplots display the interquartile range (IQR, center box), and the whiskers extend 1.5*IQR from the lower and upper hinge. The white point indicates the mean and the white center line indicates the median.


Import Data

In a first step we import the raw Qualtrics data, which was downloaded as an SPSS file.

# Reset working directory to folder current file is saved in
#setwd(dirname(rstudioapi::getActiveDocumentContext()$path))

# Import Qualtrics Survey Data
dt0Raw <- read_spss("data/raw data/Snowball+Corona+Long-Term+Coverage+-+Baseline_March+30,+2020_00.32.sav")

The raw data set includes 588 variables for 14401 cases.

Data Quality

Missing Data

Inspecting missing data in the items.

# Table: Missing Data per item
dt0Raw %>%
  select(-starts_with("t_"), -starts_with("Pol")) %>% #drop timers and Political orientation (because of translation missingness)
  select_if(~sum(is.na(.)) > 0) %>% # remove all variables that have no missingess
  naniar::miss_var_summary(.) %>% # by variable summary of missingness proportion
  DT::datatable(.,
                colnames = c("Variable", "Number Missing", "Percentage Missing"),
                filter = 'top',
                extensions = 'Buttons',
                options = list(
                  columnDefs = list(list(className = 'dt-center')),
                  #autoWidth = TRUE,
                  dom = 'Bfrtlip',
                  buttons = c('copy', 'csv', 'excel', 'pdf', 'print'))) %>%
  DT::formatRound('pct_miss', digits = 2)
# Plot: Missing Data per item
dt0Raw %>%
  select(-starts_with("t_"), -starts_with("Pol")) %>% #drop timers and Political orientation (because of translation missingness)
  select_if(~sum(is.na(.)) > 0) %>% # remove all variables that have no missingess
  naniar::gg_miss_var(.) # visualize by variable summary of missingness proportion

# Plot: Missing Data cumulative
dt0Raw %>%
  select(-starts_with("t_"), -starts_with("Pol")) %>% #drop timers and Political orientation (because of translation missingness)
  select_if(~sum(is.na(.)) > 0) %>% # remove all variables that have no missingess
  naniar::gg_miss_var_cumsum(.) # missingness development over survey

# Co-occurences of missingess - too many variables
#dt0Raw %>%
#  select(-starts_with("t_"), -starts_with("Pol")) %>% #drop timers and Political orientation (because of translation missingness)
#  select_if(~sum(is.na(.)) > 0) %>% # remove all variables that have no missingess
#  naniar::gg_miss_upset(., nsets = n_var_miss(.)) # visualize missingess co-occurences

Filter: Preview Responses

Filter the Preview responses.

# flag Preview Responses
dt1Preview <- dt0Raw %>%
  mutate(FilterPreview = labelled(ifelse(Status == 0,0,1),
                                  labels = c(preview = 1), label="Filter: survey preview response"))

Filter: Short Duration on Survey

Filter survey responses that were shorter than 10 minutes.

# truncate data:
tOutlierHigh <- dt1Preview %>%
  select(Duration__in_seconds_) %>%
  filter(Duration__in_seconds_<=stats::median(Duration__in_seconds_)+stats::mad(Duration__in_seconds_)*3.5) %>%
  mutate(Minutes = Duration__in_seconds_/60)

# set time cut-off criterion:
tCutOff <- 10 #cut-off criterion in minutes
tCutOffPerc <- round(sum(tOutlierHigh$Minutes<tCutOff)/nrow(dt1Preview)*100,2) # percent of missing data with current cut-off criterion
tOutlierHigh$out <- tOutlierHigh$Minutes < 10

# plot histogram and missing
ggplot(data=tOutlierHigh, aes(x=Minutes, fill=out)) +
  geom_histogram(bins=round(max(tOutlierHigh$Minutes),0),
                 alpha=.6) +
  geom_vline(xintercept = tCutOff, 
             color = "darkred",
             linetype = "longdash") +
  geom_text(aes(x=tCutOff, label=paste0("time cut-off: ",tCutOff," Minutes\n"), y=Inf), 
            hjust = 1,
            colour="darkred", 
            angle=90) +
  geom_text(aes(x=tCutOff, label=paste0("\ndata loss: ",tCutOffPerc,"%"), y=Inf), 
            hjust = 1,
            colour="darkred", 
            angle=90) +
  scale_x_continuous(breaks = seq(0, round(max(tOutlierHigh$Minutes),0), 5)) +
  scale_fill_manual(values=c("darkgrey","darkred")) +
  labs(title = "Truncated Histogram: Survey Duration", 
       x = "Duration [Mintues]",
       y = "Frequency Count",
       caption = "Notes:
       (1) Truncated: all participants who took less time than Median+3.5*MAD
       (2) Each bin represents one Minute") +
  theme_Publication() +
  theme(legend.position = "none")

rm(tOutlierHigh, tCutOff, tCutOffPerc)

# flag anyone with less than 10 minutes survey duration
dt2Time <- dt1Preview %>%
  mutate(FilterTime = labelled(ifelse(Duration__in_seconds_ > 600,0,1),
                               labels = c(`extremely quick` = 1), label="Filter: Took less than 10 minutes on survey"))

Filter: Straightliners

Filter participants, who have straightlined on the job insecurity scale, which includes a reverse coded item. We only flag people who straightlined outside the median categories because all “neither agree nor disagree” might be meaningful response.

# CheckMissingness pattern
naniar::gg_miss_upset(dt2Time %>%
  select(ResponseId, jbInsec01, jbInsec02, jbInsec03) %>%
  na_if(., -99) # all -99 into <NA>
)

# isolate respondents who have straightlined outside a the median categories (b/c all "neither agree nor disagree" might be meaningful response) 
jobinsecRed <- dt2Time %>%
  select(ResponseId, jbInsec01, jbInsec02, jbInsec03) %>%
  na_if(., -99) %>% # all -99 into <NA>
  na.omit() %>% # remove people who have missing data on one of the three items
  mutate(mean = rowMeans(select(., c("jbInsec01", "jbInsec02", "jbInsec03"))), 
         sd = matrixStats::rowSds(as.matrix(select(., c("jbInsec01", "jbInsec02", "jbInsec03"))))) %>% # calculate row-means and row-sds 
  filter(sd == 0, mean != 0)

# flag anyone who straightlined on job insecurity
dt3Straightliner <- dt2Time %>%
  mutate(FilterStraightliner = labelled(ifelse(!ResponseId %in% jobinsecRed$ResponseId,0,1),
                                        labels = c(straightliner = 1), label="Filter: straightliner on Job Insecurity"))
rm(jobinsecRed)

Data Preparation

Note: For each of the scales we do an item analysis, and combine the items to the mean- (.m), and factor scores (.fa). We also centered (.c) and standardized (.z) the mean scores. Most of these items are not labelled for SPSS yet.

Recoded Items

Re-coding reverse coded items and the Qualtrics language codes.

# Recoded Items
dt3Straightliner <- dt3Straightliner %>%
  mutate(jbInsec02_R = labelled(recode(as.numeric(jbInsec02), `-2` = 2, `-1` = 1, `0` = 0, `1` = -1, `2` = -2, `-99` = -99),
                                labels = NULL, label="Job Insecurity 02 (re-coded)"),
         bor03_R = labelled(recode(as.numeric(bor03), `-2` = 2, `-1` = 1, `0` = 0, `1` = -1, `2` = -2),
                            labels = NULL, label="Boredom 03 (re-coded)"))
# Language
# Import Qualtrics Language Codes
qualtricsLanguage <- read_excel("data/raw data/qualtricsLanguageCodes.xlsx")
dt3Straightliner <- merge(x=dt3Straightliner, y=qualtricsLanguage, by="Q_Language", all=TRUE)
rm(qualtricsLanguage)

Country


Action needed:
We currently have 712 different free text country responses. These need to be coded and consolidated.

#
# WORK NEEDED HERE (string finding?)
#

Political Orientation

Political orientation was measured per language. We merge these variables here.

dt4PolOr <- dt3Straightliner %>%
  mutate(PolOrX = labelled(rowSums(select(., ends_with("_x")), na.rm = T), 
                           labels = NULL, label="Political Compass X-Coordinate"),
         PolOrY = labelled(rowSums(select(., ends_with("_y")), na.rm = T), 
                           labels = NULL, label="Political Compass Y-Coordinate"),
         PolOrAuthoritarianLeft = rowSums(select(., ends_with("_Authoritarian_Left")), na.rm = T),
         PolOrAuthoritarianLeftLab = dplyr::recode(PolOrAuthoritarianLeft, `1` =  "Authoritarian Left", `0` = ""),
         PolOrAuthoritarianRight = rowSums(select(., ends_with("_Authoritarian_right")), na.rm = T),
         PolOrAuthoritarianRightLab = dplyr::recode(PolOrAuthoritarianRight, `1` =  "Authoritarian Right", `0` = ""),
         PolOrLibertarianLeft = rowSums(select(., ends_with("_Libertarian_Left")), na.rm = T),
         PolOrLibertarianLeftLab = dplyr::recode(PolOrLibertarianLeft, `1` =  "Libertarian Left", `0` = ""),
         PolOrLibertarianRight = rowSums(select(., ends_with("_Libertarian_Right")), na.rm = T),
         PolOrLibertarianRightLab = dplyr::recode(PolOrLibertarianRight, `1` =  "Libertarian Right", `0` = ""),
         PolOrOther = rowSums(select(., ends_with("_Other")), na.rm = T),
         PolOrOtherLab = dplyr::recode(PolOrOther, `1` =  "Other", `0` = ""),
         PolOrCat = paste0(PolOrAuthoritarianLeftLab, 
                           PolOrAuthoritarianRightLab,
                           PolOrLibertarianLeftLab,
                           PolOrLibertarianRightLab,
                           PolOrOtherLab),
         PolOrCat = as.factor(na_if(PolOrCat, ""))) %>%
  select(-starts_with("PolOrA"),
         -starts_with("PolOrL"),
         -starts_with("PolE"),
         -starts_with("PolD"),
         -starts_with("PolF"),
         -starts_with("PolA"),
         -starts_with("PolN"),
         -starts_with("PolI"),
         -starts_with("PolT"),
         -starts_with("PolS"),
         -starts_with("PolH"),
         -starts_with("PolP"),
         -c(PolOrOther,PolOrOtherLab))
attr(dt4PolOr$PolOrCat,'label') <- 'Political Orientation Quadrant'

Affect

High Arousal Negative

# High Arousal Negative
## Anger not measured in wave 1
pairs.panels.new(dt4PolOr %>% select(affAnx, affNerv))

cat("<br>")


dt4PolOr$affHighNeg.m <- scoreItems(keys=c(1,1), items = dt4PolOr %>% select(affAnx, affNerv), min = 1, max = 5)$scores

as.data.frame(psych::describe(dt4PolOr$affHighNeg.m, skew=F)) %>%
  mutate(vars = "High Arousal Negative Affect") %>%
  kable(., caption = "High Arousal Negative Affect: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
High Arousal Negative Affect: Scale Descriptives
vars n mean sd min max range se
High Arousal Negative Affect 14458 2.897 1.038 1 5 4 0.0086
dt4PolOr$affHighNeg.c <- scale(dt4PolOr$affHighNeg.m, scale = F, center = T)
dt4PolOr$affHighNeg.z <- scale(dt4PolOr$affHighNeg.m, scale = T)
dt4PolOr$affHighNeg.fa <- fa(dt4PolOr %>% select(affAnx, affNerv))$scores

Low Arousal Negative Affect

# Low Arousal Negative Affect
ia.affLowNeg <- dt4PolOr %>%
    dplyr::select(affBor, affExh, affDepr) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.affLowNeg$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.57 . Furthermore, deleting item(s) 1 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.affLowNeg)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
affDepr 0.4732 0.8283 2.199 1.152
affExh 0.3840 0.5209 2.524 1.230
affBor 0.2866 0.3594 2.501 1.295
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(affBor, affExh, affDepr))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Low Arousal Negative Affect: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Low Arousal Negative Affect: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
affBor 12344 2.501 1.295 2 2.401 1.483 1 5 4 0.3917 -1.0254 0.0117
affExh 12327 2.524 1.230 2 2.457 1.483 1 5 4 0.3094 -1.0094 0.0111
affDepr 12341 2.199 1.152 2 2.079 1.483 1 5 4 0.6651 -0.5391 0.0104
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(affBor, affExh, affDepr))

cat("<br>")


dt4PolOr$affLowNeg.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(affBor, affExh, affDepr), min = 1, max = 5)$scores

as.data.frame(psych::describe(dt4PolOr$affLowNeg.m, skew=F)) %>%
  mutate(vars = "Low Arousal Negative Affect") %>%
  kable(., caption = "Low Arousal Negative Affect: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Low Arousal Negative Affect: Scale Descriptives
vars n mean sd min max range se
Low Arousal Negative Affect 14458 2.348 0.8419 1 5 4 0.007
dt4PolOr$affLowNeg.c <- scale(dt4PolOr$affLowNeg.m, scale = F, center = T)
dt4PolOr$affLowNeg.z <- scale(dt4PolOr$affLowNeg.m, scale = T)
dt4PolOr$affLowNeg.fa <- fa(dt4PolOr %>% select(affBor, affExh, affDepr))$scores

Low Arousal Positive Affect

# Low Arousal Positive Affect
ia.affLowPos <- dt4PolOr %>%
    dplyr::select(affCalm, affContent, affRel) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.affLowPos$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.74 . Furthermore, deleting item(s) 2 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.affLowPos)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
affRel 0.6268 0.8116 2.528 1.099
affCalm 0.6159 0.7853 2.792 1.069
affContent 0.4463 0.5058 2.574 1.099
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(affCalm, affContent, affRel))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Low Arousal Positive Affect: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Low Arousal Positive Affect: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
affCalm 12329 2.792 1.069 3 2.811 1.483 1 5 4 0.0041 -0.7403 0.0096
affContent 12318 2.574 1.099 3 2.551 1.483 1 5 4 0.1428 -0.8217 0.0099
affRel 12324 2.528 1.099 3 2.494 1.483 1 5 4 0.2130 -0.7984 0.0099
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(affCalm, affContent, affRel))

cat("<br>")


dt4PolOr$affLowPos.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(affCalm, affContent, affRel), min = 1, max = 5)$scores

as.data.frame(psych::describe(dt4PolOr$affLowPos.m, skew=F)) %>%
  mutate(vars = "Low Arousal Positive Affect") %>%
  kable(., caption = "Low Arousal Positive Affect: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Low Arousal Positive Affect: Scale Descriptives
vars n mean sd min max range se
Low Arousal Positive Affect 14458 2.686 0.8249 1 5 4 0.0069
dt4PolOr$affLowPos.c <- scale(dt4PolOr$affLowPos.m, scale = F, center = T)
dt4PolOr$affLowPos.z <- scale(dt4PolOr$affLowPos.m, scale = T)
dt4PolOr$affLowPos.fa <- fa(dt4PolOr %>% select(affCalm, affContent, affRel))$scores

High Arousal Positive Affect

# High Arousal Positive Affect
ia.affHighPos <- dt4PolOr %>%
    dplyr::select(affEnerg, affExc, affInsp) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.affHighPos$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.67 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.affHighPos)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
affInsp 0.5265 0.7258 2.308 1.142
affEnerg 0.4898 0.6415 2.378 1.077
affExc 0.4410 0.5522 2.099 1.113
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(affEnerg, affExc, affInsp))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "High Arousal Positive Affect: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
High Arousal Positive Affect: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
affEnerg 12318 2.378 1.077 2 2.314 1.483 1 5 4 0.3196 -0.7006 0.0097
affExc 12315 2.099 1.113 2 1.969 1.483 1 5 4 0.6913 -0.5068 0.0100
affInsp 12327 2.308 1.142 2 2.217 1.483 1 5 4 0.4658 -0.7418 0.0103
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(affEnerg, affExc, affInsp))

cat("<br>")


dt4PolOr$affHighPos.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(affEnerg, affExc, affInsp), min = 1, max = 5)$scores

as.data.frame(psych::describe(dt4PolOr$affHighPos.m, skew=F)) %>%
  mutate(vars = "High Arousal Positive Affect") %>%
  kable(., caption = "High Arousal Positive Affect: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
High Arousal Positive Affect: Scale Descriptives
vars n mean sd min max range se
High Arousal Positive Affect 14458 2.223 0.8084 1 5 4 0.0067
dt4PolOr$affHighPos.c <- scale(dt4PolOr$affHighPos.m, scale = F, center = T)
dt4PolOr$affHighPos.z <- scale(dt4PolOr$affHighPos.m, scale = T)
dt4PolOr$affHighPos.fa <- fa(dt4PolOr %>% select(affEnerg, affExc, affInsp))$scores

Loneliness

ia.lone<- dt4PolOr %>%
    dplyr::select(starts_with("lone")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.lone$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.8 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.lone)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
lone01 0.6827 0.8219 2.332 1.133
lone02 0.6372 0.7399 2.642 1.217
lone03 0.6196 0.7115 1.945 1.092
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("lone")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Loneliness: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Loneliness: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
lone01 12219 2.332 1.133 2 2.251 1.483 1 5 4 0.4004 -0.7876 0.0102
lone02 12208 2.642 1.217 3 2.599 1.483 1 5 4 0.1507 -1.0071 0.0110
lone03 12204 1.945 1.092 2 1.774 1.483 1 5 4 0.9601 0.0146 0.0099
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("lone")))

cat("<br>")


dt4PolOr$lone.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(starts_with("lone")), min = 1, max = 5)$scores

as.data.frame(psych::describe(dt4PolOr$lone.m, skew=F)) %>%
  mutate(vars = "Loneliness") %>%
  kable(., caption = "Loneliness: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Loneliness: Scale Descriptives
vars n mean sd min max range se
Loneliness 14458 2.311 0.8944 1 5 4 0.0074
dt4PolOr$lone.c <- scale(dt4PolOr$lone.m, scale = F, center = T)
dt4PolOr$lone.z <- scale(dt4PolOr$lone.m, scale = T)
dt4PolOr$lone.fa <- fa(dt4PolOr %>% select(starts_with("lone")))$scores

Boredom

ia.bor<- dt4PolOr %>%
    dplyr::select(starts_with("bor0"), -bor03) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.bor$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.51 . Item(s) that exhibited low correlation with the rest of the scale were: 3 . Furthermore, deleting item(s) 3 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.bor)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
bor02 0.4888 0.7379 0.1007 1.878
bor01 0.4635 0.7304 0.4189 1.902
bor03_R 0.0776 0.4080 -0.2824 1.681
pairs.panels.new(dt4PolOr %>% select(starts_with("bor0"), -bor03))

Item dropped:
Item three was not well behaved. It seems to measure something else. We dropped it for now.

pairs.panels.new(dt4PolOr %>% select(starts_with("bor0"), -bor03, -bor03_R))

cat("<br>")


dt4PolOr$bor.m <- scoreItems(keys=c(1,1), items = dt4PolOr %>% select(starts_with("bor0"), -bor03, -bor03_R), min = -3, max = 3)$scores

as.data.frame(psych::describe(dt4PolOr$bor.m, skew=F)) %>%
  mutate(vars = "Boredom") %>%
  kable(., caption = "Boredom: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Boredom: Scale Descriptives
vars n mean sd min max range se
Boredom 14458 0.2125 1.545 -3 3 6 0.0128
dt4PolOr$bor.c <- scale(dt4PolOr$bor.m, scale = F, center = T)
dt4PolOr$bor.z <- scale(dt4PolOr$bor.m, scale = T)
dt4PolOr$bor.fa <- fa(dt4PolOr %>% select(starts_with("bor0"), -bor03, -bor03_R))$scores

Isolation

cat(crayon::bold("Offline Isolation"))

Offline Isolation

ia.isoPers <- dt4PolOr %>%
    dplyr::select(ends_with("inPerson")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.isoPers$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.58 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.isoPers)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
isoOthPpl_inPerson 0.4618 0.7605 1.955 2.205
isoImmi_inPerson 0.3782 0.5165 0.501 1.419
isoFriends_inPerson 0.3316 0.4334 2.067 2.482
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(ends_with("inPerson")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Isolation offline: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Isolation offline: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
isoFriends_inPerson 12158 2.067 2.482 1 1.708 1.483 0 7 7 0.9742 -0.4959 0.0225
isoOthPpl_inPerson 12105 1.955 2.205 1 1.597 1.483 0 7 7 1.0423 -0.0553 0.0200
isoImmi_inPerson 12033 0.501 1.419 0 0.087 0.000 0 7 7 3.2382 10.0072 0.0129
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(ends_with("inPerson")))

cat("<br>")


dt4PolOr$isoPers.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(ends_with("inPerson")), min = 0, max = 7)$scores

as.data.frame(psych::describe(dt4PolOr$isoPers.m, skew=F)) %>%
  mutate(vars = "Isolation offline") %>%
  kable(., caption = "Isolation offline: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Isolation offline: Scale Descriptives
vars n mean sd min max range se
Isolation offline 14458 1.371 1.437 0 7 7 0.0119
dt4PolOr$isoPers.c <- scale(dt4PolOr$isoPers.m, scale = F, center = T)
dt4PolOr$isoPers.z <- scale(dt4PolOr$isoPers.m, scale = T)
dt4PolOr$isoPers.fa <- fa(dt4PolOr %>% select(ends_with("inPerson")))$scores

cat(crayon::bold("Online Isolation"))

Online Isolation

ia.isoOnl <- dt4PolOr %>%
    dplyr::select(ends_with("online")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.isoOnl$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.54 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.isoOnl)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
isoOthPpl_online 0.4658 0.9355 2.9763 2.730
isoFriends_online 0.3011 0.3776 4.8793 2.347
isoImmi_online 0.2990 0.3746 0.8074 1.885
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(ends_with("inPerson")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Isolation online: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Isolation online: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
isoFriends_inPerson 12158 2.067 2.482 1 1.708 1.483 0 7 7 0.9742 -0.4959 0.0225
isoOthPpl_inPerson 12105 1.955 2.205 1 1.597 1.483 0 7 7 1.0423 -0.0553 0.0200
isoImmi_inPerson 12033 0.501 1.419 0 0.087 0.000 0 7 7 3.2382 10.0072 0.0129
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(ends_with("online")))

cat("<br>")


dt4PolOr$isoOnl.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(ends_with("online")), min = 0, max = 7)$scores

as.data.frame(psych::describe(dt4PolOr$isoPers.m, skew=F)) %>%
  mutate(vars = "Isolation online") %>%
  kable(., caption = "Isolation online: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Isolation online: Scale Descriptives
vars n mean sd min max range se
Isolation online 14458 1.371 1.437 0 7 7 0.0119
dt4PolOr$isoOnl.c <- scale(dt4PolOr$isoOnl.m, scale = F, center = T)
dt4PolOr$isoOnl.z <- scale(dt4PolOr$isoOnl.m, scale = T)
dt4PolOr$isoOnl.fa <- fa(dt4PolOr %>% select(ends_with("online")))$scores

# Leave House
as.data.frame(psych::describe(dt4PolOr$houseLeave, skew=F)) %>%
  mutate(vars = "Leaving House") %>%
  kable(., caption = "Leaving House: Item Descriptive", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Leaving House: Item Descriptive
vars n mean sd min max range se
Leaving House 11876 2.438 1.07 1 4 3 0.0098

Government Response

No responses yet

# extC19Msg

Community Response

ia.ext <- dt4PolOr %>%
    dplyr::select(starts_with("extC19"), -extC19Msg) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.ext$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.77 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.ext)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
extC19Rules 0.7054 0.9270 4.050 1.456
extC19Org 0.5827 0.6724 3.743 1.432
extC19Punish 0.5358 0.6037 3.140 1.669
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("extC19"), -extC19Msg))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Community response: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Community response: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
extC19Rules 11967 4.050 1.456 4 4.138 1.483 1 6 5 -0.4138 -0.7261 0.0133
extC19Punish 11962 3.140 1.669 3 3.051 1.483 1 6 5 0.2305 -1.1750 0.0153
extC19Org 11967 3.743 1.432 4 3.774 1.483 1 6 5 -0.1904 -0.7870 0.0131
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("extC19"), -extC19Msg))

cat("<br>")


dt4PolOr$ext.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(starts_with("extC19"), -extC19Msg), 
                             min = 1, max = 6)$scores

as.data.frame(psych::describe(dt4PolOr$ext.m, skew=F)) %>%
  mutate(vars = "Community response") %>%
  kable(., caption = "Community response: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Community response: Scale Descriptives
vars n mean sd min max range se
Community response 14458 3.648 1.145 1 6 5 0.0095
dt4PolOr$ext.c <- scale(dt4PolOr$ext.m, scale = F, center = T)
dt4PolOr$ext.z <- scale(dt4PolOr$ext.m, scale = T)
dt4PolOr$ext.fa <- fa(dt4PolOr %>% select(starts_with("extC19"), -extC19Msg))$scores

Behavioral Response

ia.beh <- dt4PolOr %>%
    dplyr::select(starts_with("c19per")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.beh$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.68 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.beh)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
c19perBeh02 0.6036 0.9016 2.622 0.8603
c19perBeh03 0.4663 0.5644 2.073 1.3758
c19perBeh01 0.4304 0.5100 2.468 0.9603
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("c19per")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Behavioral response: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Behavioral response: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
c19perBeh01 12009 2.468 0.9603 3 2.684 0 -3 3 6 -2.879 10.787 0.0088
c19perBeh02 12012 2.622 0.8603 3 2.816 0 -3 3 6 -3.577 16.371 0.0078
c19perBeh03 12013 2.073 1.3758 3 2.375 0 -3 3 6 -1.862 3.236 0.0126
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("c19per")))

cat("<br>")


dt4PolOr$beh.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(starts_with("c19per")), 
                             min = -3, max = 3)$scores

as.data.frame(psych::describe(dt4PolOr$beh.m, skew=F)) %>%
  mutate(vars = "Behavioral response") %>%
  kable(., caption = "Behavioral response: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Behavioral response: Scale Descriptives
vars n mean sd min max range se
Behavioral response 14458 2.491 0.8035 -3 3 6 0.0067
dt4PolOr$beh.c <- scale(dt4PolOr$beh.m, scale = F, center = T)
dt4PolOr$beh.z <- scale(dt4PolOr$beh.m, scale = T)
dt4PolOr$beh.fa <- fa(dt4PolOr %>% select(starts_with("c19per")))$scores

Hope and Efficacy

as.data.frame(psych::describe(dt4PolOr$c19Hope)) %>%
  mutate(vars = "Hope") %>%
  kable(., caption = "Hope: Item Descriptive", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Hope: Item Descriptive
vars n mean sd median trimmed mad min max range skew kurtosis se
Hope 12039 1.038 1.622 1 1.211 1.483 -3 3 6 -0.7986 -0.2141 0.0148
ggplot(dt4PolOr, aes(x = c19Hope)) +
  geom_histogram(binwidth=1, alpha=0.5) +
  #geom_density(alpha=0.6)+
  labs(title="Hope distribution",x="Corona Virus Hope", y = "Frequency") +
  theme_Publication()

as.data.frame(psych::describe(dt4PolOr$c19Eff)) %>%
  mutate(vars = "Efficacy") %>%
  kable(., caption = "Efficacy: Item Descriptive", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Efficacy: Item Descriptive
vars n mean sd median trimmed mad min max range skew kurtosis se
Efficacy 12035 0.7914 1.658 1 0.9204 1.483 -3 3 6 -0.6522 -0.4741 0.0151
ggplot(dt4PolOr, aes(x = c19Eff)) +
  geom_histogram(binwidth=1, alpha=0.5) +
  #geom_density(alpha=0.6)+
  labs(title="Efficacy distribution",x="Corona Virus Efficacy", y = "Frequency") +
  theme_Publication()

State Paranoia

ia.para <- dt4PolOr %>%
    dplyr::select(starts_with("para")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.para$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.71 . Furthermore, deleting item(s) 1 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.para)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
para02 0.6332 0.8824 2.381 2.600
para03 0.5701 0.7143 2.325 2.623
para01 0.4008 0.4533 5.282 3.014
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("para")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "State Paranoia: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
State Paranoia: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
para01 11712 5.282 3.014 6 5.359 2.965 0 10 10 -0.2445 -0.9668 0.0278
para02 11708 2.381 2.600 2 1.988 2.965 0 10 10 1.0278 0.2353 0.0240
para03 11707 2.325 2.623 1 1.913 1.483 0 10 10 1.0573 0.2038 0.0242
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("para")))

cat("<br>")


dt4PolOr$para.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(starts_with("para")), 
                             min = 0, max = 10)$scores

as.data.frame(psych::describe(dt4PolOr$para.m, skew=F)) %>%
  mutate(vars = "State Paranoia") %>%
  kable(., caption = "State Paranoia: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
State Paranoia: Scale Descriptives
vars n mean sd min max range se
State Paranoia 14458 3.267 1.972 0 10 10 0.0164
dt4PolOr$para.c <- scale(dt4PolOr$para.m, scale = F, center = T)
dt4PolOr$para.z <- scale(dt4PolOr$para.m, scale = T)
dt4PolOr$para.fa <- fa(dt4PolOr %>% select(starts_with("para")))$scores

Conspiracy Theory

ia.consp <- dt4PolOr %>%
    dplyr::select(starts_with("consp")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.consp$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.69 . Furthermore, deleting item(s) 3 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.consp)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
consp02 0.5997 0.8273 7.200 2.479
consp01 0.5749 0.7564 6.888 2.616
consp03 0.3693 0.4205 5.325 2.735
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("consp")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Conspiracy Theory: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Conspiracy Theory: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
consp01 11705 6.888 2.616 7 7.168 2.965 0 10 10 -0.6867 -0.2185 0.0242
consp02 11694 7.200 2.479 8 7.504 2.965 0 10 10 -0.8578 0.1660 0.0229
consp03 11696 5.325 2.735 5 5.371 2.965 0 10 10 -0.1192 -0.7538 0.0253
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("consp")))

cat("<br>")


dt4PolOr$consp.m <- scoreItems(keys=c(1,1,1), items = dt4PolOr %>% select(starts_with("consp")), 
                             min = 0, max = 10)$scores

as.data.frame(psych::describe(dt4PolOr$consp.m, skew=F)) %>%
  mutate(vars = "Conspiracy Theory") %>%
  kable(., caption = "Conspiracy Theory: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Conspiracy Theory: Scale Descriptives
vars n mean sd min max range se
Conspiracy Theory 14458 6.508 1.855 0 10 10 0.0154
dt4PolOr$para.c <- scale(dt4PolOr$consp.m, scale = F, center = T)
dt4PolOr$para.z <- scale(dt4PolOr$consp.m, scale = T)
dt4PolOr$para.fa <- fa(dt4PolOr %>% select(starts_with("consp")))$scores

Job Insecurity

ia.jobinsec<- dt4PolOr %>%
    dplyr::select(starts_with("jbInsec"), -jbInsec02, -jbInsec04) %>%
    na_if(., -99) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.jobinsec$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.85 .

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.jobinsec)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
jbInsec01 0.7612 0.8769 -0.7671 1.178
jbInsec03 0.7168 0.8014 -0.0667 1.381
jbInsec02_R 0.6848 0.7530 -0.7225 1.163
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("jbInsec"), -jbInsec02, -jbInsec04) %>% na_if(., -99))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Job insecurity: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Job insecurity: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
jbInsec01 8991 -0.7671 1.178 -1 -0.9101 1.483 -2 2 4 0.7677 -0.2545 0.0124
jbInsec03 9773 -0.0667 1.381 0 -0.0834 1.483 -2 2 4 0.0212 -1.3020 0.0140
jbInsec02_R 9277 -0.7225 1.163 -1 -0.8482 1.483 -2 2 4 0.6778 -0.3598 0.0121
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("jbInsec"), -jbInsec02, -jbInsec04) %>% na_if(., -99))

cat("<br>")


dt4PolOr$jobinsec.m <- scoreItems(keys=c(1,1,1), 
                                  items = dt4PolOr %>% select(starts_with("jbInsec"), -jbInsec02, -jbInsec04) %>% na_if(., -99),
                                  min = -2, max = 2)$scores

as.data.frame(psych::describe(dt4PolOr$jobinsec.m, skew=F)) %>%
  mutate(vars = "Job insecurity") %>%
  kable(., caption = "Job insecurity: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Job insecurity: Scale Descriptives
vars n mean sd min max range se
Job insecurity 14458 -0.5741 0.8519 -2 2 4 0.0071
dt4PolOr$jobinsec.c <- scale(dt4PolOr$jobinsec.m, scale = F, center = T)
dt4PolOr$jobinsec.z <- scale(dt4PolOr$jobinsec.m, scale = T)
dt4PolOr$jobinsec.fa <- fa(dt4PolOr %>% select(starts_with("jbInsec"), -jbInsec02, -jbInsec04))$scores

Financial Strain

ia.pfs<- dt4PolOr %>%
    dplyr::select(starts_with("PFS0")) %>%
    Scale::Scale() %>%
    Scale::ItemAnalysis()
ia.pfs$rely   

Reliability Analysis of . ScaleData object.

A spearman correlation matrix of 3 items was calculated and submitted to Reliability analysis.

The overall Cronbach’s Alpha was 0.85 . Furthermore, deleting item(s) 2 may improve reliability.

cat("<br><br>A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:")



A gls factor analysis was conducted. Items were regressed to a single factor. Their loadings are the following:

as.data.frame(Scale::ReportTable(ia.pfs)) %>%
  kable(., row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Item Corr. to scale Factor Loading Mean SD
PFS01 0.7994 0.9361 -0.2150 1.250
PFS03 0.7597 0.8602 -0.4728 1.249
PFS02 0.6109 0.6462 0.4447 1.212
cat("<br>")


as.data.frame(psych::describe(dt4PolOr %>% select(starts_with("PFS0")))) %>%
  mutate(vars = rownames(.)) %>%
  kable(., caption = "Financial Strain: Item Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
Financial Strain: Item Descriptives
vars n mean sd median trimmed mad min max range skew kurtosis se
PFS01 12185 -0.2150 1.250 0 -0.2687 1.483 -2 2 4 0.184 -1.0404 0.0113
PFS02 12193 0.4447 1.212 1 0.5441 1.483 -2 2 4 -0.581 -0.6659 0.0110
PFS03 12194 -0.4728 1.249 -1 -0.5654 1.483 -2 2 4 0.449 -0.8835 0.0113
cat("<br>")


pairs.panels.new(dt4PolOr %>% select(starts_with("PFS0")))

cat("<br>")


dt4PolOr$pfs.m <- scoreItems(keys=c(1,1,1), 
                                  items = dt4PolOr %>% select(starts_with("PFS0")),
                                  min = -2, max = 2)$scores

as.data.frame(psych::describe(dt4PolOr$pfs.m, skew=F)) %>%
  mutate(vars = "inancial Strain") %>%
  kable(., caption = "inancial Strain: Scale Descriptives", row.names = FALSE) %>% 
  kable_styling("hover", full_width = F, latex_options = "hold_position")
inancial Strain: Scale Descriptives
vars n mean sd min max range se
inancial Strain 14458 -0.0683 0.9981 -2 2 4 0.0083
dt4PolOr$pfs.c <- scale(dt4PolOr$pfs.m, scale = F, center = T)
dt4PolOr$pfs.z <- scale(dt4PolOr$pfs.m, scale = T)
dt4PolOr$pfs.fa <- fa(dt4PolOr %>% select(starts_with("PFS0")))$scores

Reduce to Relevant Variales

# remove directly identifiable data (with and without page timers)
dt5ReducedTimer <- dt4PolOr %>%
  select(-c(IPAddress, 
            RecipientLastName, 
            RecipientFirstName, 
            RecipientEmail, 
            ExternalReference, 
            LocationLatitude, 
            LocationLongitude,
            DistributionChannel,
            ICRec_1_TEXT))
dt5Reduced <- dt5ReducedTimer %>%
  select(-starts_with("t_"))

# remove filtered cases (with and without page timers)
dt5ReducedTimerCases <- dt5ReducedTimer %>%
  filter(FilterPreview == 0,
         FilterTime == 0,
         FilterStraightliner == 0) %>%
  select(-starts_with("Filter"))
dt5ReducedCases <- dt5Reduced %>%
  filter(FilterPreview == 0,
         FilterTime == 0,
         FilterStraightliner == 0) %>%
  select(-starts_with("Filter"))

Export

Export main dataframe as RData and SPSS sav files. We export versions with and without page timers

namSPSS <- paste0("data/cleaned data/Psycorona Baseline cleaned ", format(Sys.time(), format = "%F %H-%M %Z"),".sav")
namR <- paste0("data/cleaned data/Psycorona Baseline cleaned ", format(Sys.time(), format = "%F %H-%M %Z"),".RData")
namTSPSS <- paste0("data/cleaned data/Psycorona Baseline cleaned with page timer ", format(Sys.time(), format = "%F %H-%M %Z"),".sav")
namTR <- paste0("data/cleaned data/Psycorona Baseline cleaned with page timer ", format(Sys.time(), format = "%F %H-%M %Z"),".RData")
write_sav(dt5Reduced, namSPSS)
write_sav(dt5ReducedTimer, namTSPSS)
save(dt5Reduced, file = namR)
save(dt5ReducedTimer, file = namTR)
rm(list=ls(pattern="nam"))